<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="keywords" content="Hexo Theme Keep">
    <meta name="description" content="Hexo Theme Keep">
    <meta name="author" content="Da">
    
    <title>
        
            JavaFX学习之按钮点击事件与快捷键绑定 |
        
        Da的个人博客
    </title>
    
<link rel="stylesheet" href="/css/style.css">

    <link rel="shortcut icon" href="/images/logo.svg">
    
<link rel="stylesheet" href="/css/font-awesome.min.css">

    <script id="hexo-configurations">
    let KEEP = window.KEEP || {};
    KEEP.hexo_config = {"hostname":"da9527.gitee.io","root":"/","language":"zh-CN","path":"search.json"};
    KEEP.theme_config = {"toc":{"enable":true,"number":false,"expand_all":false,"init_open":false},"style":{"primary_color":"#CC0000","avatar":"/images/avatar.svg","favicon":"/images/logo.svg","article_img_align":"left","left_side_width":"260px","content_max_width":"920px","hover":{"shadow":true,"scale":true},"first_screen":{"enable":true,"background_img":"/images/bg.svg","description":"我不怕千万人阻挡,只怕自己投降"},"scroll":{"progress_bar":{"enable":false},"percent":{"enable":false}}},"local_search":{"enable":true,"preload":false},"code_copy":{"enable":true,"style":"default"},"pjax":{"enable":true},"lazyload":{"enable":true},"version":"3.4.2"};
    KEEP.language_ago = {"second":"%s 秒前","minute":"%s 分钟前","hour":"%s 小时前","day":"%s 天前","week":"%s 周前","month":"%s 月前","year":"%s 年前"};
  </script>
<meta name="generator" content="Hexo 5.4.0"></head>


<body>
<div class="progress-bar-container">
    

    
        <span class="pjax-progress-bar"></span>
        <span class="pjax-progress-icon">
            <i class="fas fa-circle-notch fa-spin"></i>
        </span>
    
</div>


<main class="page-container">

    

    <div class="page-main-content">

        <div class="page-main-content-top">
            <header class="header-wrapper">

    <div class="header-content">
        <div class="left">
            <a class="logo-title" href="/">
                Da的个人博客
            </a>
        </div>

        <div class="right">
            <div class="pc">
                <ul class="menu-list">
                    
                        <li class="menu-item">
                            <a class=""
                               href="/"
                            >
                                首页
                            </a>
                        </li>
                    
                        <li class="menu-item">
                            <a class=""
                               href="/archives"
                            >
                                归档
                            </a>
                        </li>
                    
                        <li class="menu-item">
                            <a class=""
                               href="/about"
                            >
                                关于
                            </a>
                        </li>
                    
                    
                        <li class="menu-item search search-popup-trigger">
                            <i class="fas fa-search"></i>
                        </li>
                    
                </ul>
            </div>
            <div class="mobile">
                
                    <div class="icon-item search search-popup-trigger"><i class="fas fa-search"></i></div>
                
                <div class="icon-item menu-bar">
                    <div class="menu-bar-middle"></div>
                </div>
            </div>
        </div>
    </div>

    <div class="header-drawer">
        <ul class="drawer-menu-list">
            
                <li class="drawer-menu-item flex-center">
                    <a class=""
                       href="/">首页</a>
                </li>
            
                <li class="drawer-menu-item flex-center">
                    <a class=""
                       href="/archives">归档</a>
                </li>
            
                <li class="drawer-menu-item flex-center">
                    <a class=""
                       href="/about">关于</a>
                </li>
            
        </ul>
    </div>

    <div class="window-mask"></div>

</header>


        </div>

        <div class="page-main-content-middle">

            <div class="main-content">

                
                    <div class="fade-in-down-animation">
    <div class="article-content-container">

        <div class="article-title">
            <span class="title-hover-animation">JavaFX学习之按钮点击事件与快捷键绑定</span>
        </div>

        
            <div class="article-header">
                <div class="avatar">
                    <img src="/images/avatar.svg">
                </div>
                <div class="info">
                    <div class="author">
                        <span class="name">Da</span>
                        
                            <span class="author-label">Lv4</span>
                        
                    </div>
                    <div class="meta-info">
                        <div class="article-meta-info">
    <span class="article-date article-meta-item">
        <i class="fas fa-edit"></i>&nbsp;2021-05-22 11:53:29
    </span>
    
    

    
    
        <span class="article-wordcount article-meta-item">
            <i class="fas fa-file-word"></i>&nbsp;<span>671 字</span>
        </span>
    
    
        <span class="article-min2read article-meta-item">
            <i class="fas fa-clock"></i>&nbsp;<span>3 分钟</span>
        </span>
    
    
        <span class="article-pv article-meta-item">
            <i class="fas fa-eye"></i>&nbsp;<span id="busuanzi_value_page_pv"></span>
        </span>
    
</div>

                    </div>
                </div>
            </div>
        

        <div class="article-content markdown-body">
            <h1 id="JavaFX的第七次接触"><a href="#JavaFX的第七次接触" class="headerlink" title="JavaFX的第七次接触"></a>JavaFX的第七次接触</h1><blockquote>
<p> 按键单击、多击事件</p>
<p> 快捷键绑定</p>
</blockquote>
<figure class="highlight java"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br><span class="line">94</span><br><span class="line">95</span><br><span class="line">96</span><br><span class="line">97</span><br><span class="line">98</span><br><span class="line">99</span><br><span class="line">100</span><br><span class="line">101</span><br><span class="line">102</span><br><span class="line">103</span><br><span class="line">104</span><br><span class="line">105</span><br><span class="line">106</span><br><span class="line">107</span><br><span class="line">108</span><br><span class="line">109</span><br><span class="line">110</span><br><span class="line">111</span><br><span class="line">112</span><br><span class="line">113</span><br><span class="line">114</span><br><span class="line">115</span><br><span class="line">116</span><br><span class="line">117</span><br><span class="line">118</span><br><span class="line">119</span><br><span class="line">120</span><br><span class="line">121</span><br><span class="line">122</span><br><span class="line">123</span><br><span class="line">124</span><br><span class="line">125</span><br><span class="line">126</span><br><span class="line">127</span><br></pre></td><td class="code"><pre><span class="line"><span class="keyword">import</span> javafx.application.Application;</span><br><span class="line"><span class="keyword">import</span> javafx.event.EventHandler;</span><br><span class="line"><span class="keyword">import</span> javafx.scene.Group;</span><br><span class="line"><span class="keyword">import</span> javafx.scene.Scene;</span><br><span class="line"><span class="keyword">import</span> javafx.scene.control.Button;</span><br><span class="line"><span class="keyword">import</span> javafx.scene.input.*;</span><br><span class="line"><span class="keyword">import</span> javafx.stage.Stage;</span><br><span class="line"></span><br><span class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">class</span> <span class="title">Main</span> <span class="keyword">extends</span> <span class="title">Application</span> </span>&#123;</span><br><span class="line"></span><br><span class="line">    <span class="function"><span class="keyword">public</span> <span class="keyword">static</span> <span class="keyword">void</span> <span class="title">main</span><span class="params">(String[] args)</span> </span>&#123;</span><br><span class="line">        launch(args);</span><br><span class="line">    &#125;</span><br><span class="line"></span><br><span class="line">    <span class="meta">@Override</span></span><br><span class="line">    <span class="function"><span class="keyword">public</span> <span class="keyword">void</span> <span class="title">start</span><span class="params">(Stage primaryStage)</span> <span class="keyword">throws</span> Exception </span>&#123;</span><br><span class="line"></span><br><span class="line">        Button b1 = <span class="keyword">new</span> Button(<span class="string">&quot;b1&quot;</span>);</span><br><span class="line">        b1.setPrefWidth(<span class="number">200</span>);</span><br><span class="line">        b1.setPrefHeight(<span class="number">100</span>);</span><br><span class="line">        b1.setLayoutX(<span class="number">10</span>);</span><br><span class="line">        b1.setLayoutY(<span class="number">10</span>);</span><br><span class="line">        b1.setStyle(<span class="string">&quot;-fx-font-size: 20;&quot;</span> +</span><br><span class="line">                    <span class="string">&quot;-fx-text-fill: #fff;&quot;</span> +</span><br><span class="line">                    <span class="string">&quot;-fx-background-color: #2ecc71;&quot;</span>);</span><br><span class="line"></span><br><span class="line">        Button b2 = <span class="keyword">new</span> Button(<span class="string">&quot;b2&quot;</span>);</span><br><span class="line">        b2.setPrefWidth(<span class="number">200</span>);</span><br><span class="line">        b2.setPrefHeight(<span class="number">100</span>);</span><br><span class="line">        b2.setLayoutX(<span class="number">220</span>);</span><br><span class="line">        b2.setLayoutY(<span class="number">10</span>);</span><br><span class="line">        b2.setStyle(<span class="string">&quot;-fx-font-size: 20;&quot;</span> +</span><br><span class="line">                    <span class="string">&quot;-fx-text-fill: #fff;&quot;</span> +</span><br><span class="line">                    <span class="string">&quot;-fx-background-color: #8e44ad;&quot;</span>);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        第一种鼠标左键单击事件</span></span><br><span class="line">        b1.setOnAction(e -&gt; &#123;</span><br><span class="line">            System.out.println(((Button)e.getSource()).getText() + <span class="string">&quot;的单击事件&quot;</span>);</span><br><span class="line">        &#125;);</span><br><span class="line"><span class="comment">//        第二种鼠标单击事件与鼠标双击事件(多击事件)</span></span><br><span class="line">        b1.addEventHandler(MouseEvent.MOUSE_CLICKED, <span class="keyword">new</span> EventHandler&lt;MouseEvent&gt;() &#123;</span><br><span class="line">            <span class="meta">@Override</span></span><br><span class="line">            <span class="function"><span class="keyword">public</span> <span class="keyword">void</span> <span class="title">handle</span><span class="params">(MouseEvent event)</span> </span>&#123;</span><br><span class="line"></span><br><span class="line"><span class="comment">//                System.out.println(&quot;addEventHandler事件鼠标单击&quot;);</span></span><br><span class="line"><span class="comment">//                System.out.println(&quot;当前鼠标按键 =&gt; &quot; + event.getButton().name());//event.getButton().name()获取哪个鼠标按键点的</span></span><br><span class="line"></span><br><span class="line"><span class="comment">//                if (event.getClickCount() == 2)&#123;//判断鼠标点击的次数</span></span><br><span class="line"><span class="comment">//                    System.out.println(&quot;鼠标双击了...&quot;);</span></span><br><span class="line"><span class="comment">//                &#125;</span></span><br><span class="line">                <span class="keyword">if</span> (event.getClickCount() == <span class="number">3</span>)&#123;</span><br><span class="line">                    System.out.println(<span class="string">&quot;鼠标3击了...&quot;</span>);</span><br><span class="line">                &#125;</span><br><span class="line"><span class="comment">//                鼠标右键双击触发</span></span><br><span class="line">                <span class="keyword">if</span> (event.getClickCount() == <span class="number">2</span> &amp;&amp; event.getButton().name().equals(MouseButton.SECONDARY.name()))&#123;</span><br><span class="line">                    System.out.println(<span class="string">&quot;鼠标右键双击了&quot;</span>);</span><br><span class="line">                &#125;</span><br><span class="line">            &#125;</span><br><span class="line">        &#125;);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        lambda写法</span></span><br><span class="line">        b2.addEventHandler(MouseEvent.MOUSE_CLICKED,e -&gt; &#123;</span><br><span class="line">            <span class="keyword">if</span> (e.getClickCount() == <span class="number">2</span> &amp;&amp; e.getButton().name().equals(MouseButton.PRIMARY.name()))&#123;</span><br><span class="line">                System.out.println(<span class="string">&quot;鼠标左键双击&quot;</span>);</span><br><span class="line">            &#125;</span><br><span class="line">        &#125;);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        监听键盘事件,点击了之后才会监听</span></span><br><span class="line">        b2.setOnKeyPressed(<span class="keyword">new</span> EventHandler&lt;KeyEvent&gt;() &#123;</span><br><span class="line">            <span class="meta">@Override</span></span><br><span class="line">            <span class="function"><span class="keyword">public</span> <span class="keyword">void</span> <span class="title">handle</span><span class="params">(KeyEvent event)</span> </span>&#123;</span><br><span class="line">                System.out.println(event.getCode().getName() + <span class="string">&quot;按下&quot;</span>);</span><br><span class="line">                <span class="keyword">if</span> (event.getCode().name().equals(KeyCode.Q.name()))&#123;<span class="comment">//条件过滤</span></span><br><span class="line">                    System.out.println(<span class="string">&quot;Q按下了...&quot;</span>);</span><br><span class="line">                &#125;</span><br><span class="line"></span><br><span class="line">            &#125;</span><br><span class="line">        &#125;);</span><br><span class="line">        b2.setOnKeyReleased(<span class="keyword">new</span> EventHandler&lt;KeyEvent&gt;() &#123;</span><br><span class="line">            <span class="meta">@Override</span></span><br><span class="line">            <span class="function"><span class="keyword">public</span> <span class="keyword">void</span> <span class="title">handle</span><span class="params">(KeyEvent event)</span> </span>&#123;</span><br><span class="line">                System.out.println(event.getCode().getName() + <span class="string">&quot;释放&quot;</span>);</span><br><span class="line">            &#125;</span><br><span class="line">        &#125;);</span><br><span class="line"></span><br><span class="line">        Group group = <span class="keyword">new</span> Group();</span><br><span class="line">        group.getChildren().addAll(b1,b2);</span><br><span class="line"></span><br><span class="line">        Scene scene = <span class="keyword">new</span> Scene(group);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        设置快捷键</span></span><br><span class="line"><span class="comment">//        第一种方式</span></span><br><span class="line">        KeyCodeCombination kc1 = <span class="keyword">new</span> KeyCodeCombination(KeyCode.C, KeyCombination.ALT_DOWN, KeyCombination.CONTROL_DOWN);</span><br><span class="line">        Mnemonic mc1 = <span class="keyword">new</span> Mnemonic(b1, kc1);<span class="comment">//绑定b1按钮的点击事件</span></span><br><span class="line">        scene.addMnemonic(mc1);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        第二种方式</span></span><br><span class="line">        KeyCharacterCombination kc2 = <span class="keyword">new</span> KeyCharacterCombination(<span class="string">&quot;O&quot;</span>, KeyCombination.ALT_DOWN);</span><br><span class="line">        Mnemonic mc2 = <span class="keyword">new</span> Mnemonic(b1, kc2);<span class="comment">//绑定b1按钮的点击事件</span></span><br><span class="line">        scene.addMnemonic(mc2);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        第三种,太长略过</span></span><br><span class="line"></span><br><span class="line"><span class="comment">//        第四种,这种方式比较推荐,可以写逻辑</span></span><br><span class="line">        KeyCodeCombination kc4 = <span class="keyword">new</span> KeyCodeCombination(KeyCode.Y, KeyCombination.SHIFT_DOWN);</span><br><span class="line">        scene.getAccelerators().put(kc4, <span class="keyword">new</span> Runnable() &#123;</span><br><span class="line">            <span class="meta">@Override</span></span><br><span class="line">            <span class="function"><span class="keyword">public</span> <span class="keyword">void</span> <span class="title">run</span><span class="params">()</span> </span>&#123;</span><br><span class="line"><span class="comment">//                虽然有Runnable当是不是新的线程</span></span><br><span class="line">                System.out.println(<span class="string">&quot;run方法&quot;</span> + Thread.currentThread().getName());</span><br><span class="line">                b1.fire();<span class="comment">//执行b1按钮的单击事件</span></span><br><span class="line">            &#125;</span><br><span class="line">        &#125;);</span><br><span class="line"></span><br><span class="line"><span class="comment">//        第五种</span></span><br><span class="line">        KeyCombination kc5 = KeyCombination.valueOf(<span class="string">&quot;alt+k&quot;</span>);</span><br><span class="line">        Mnemonic mc3 = <span class="keyword">new</span> Mnemonic(b1, kc5);</span><br><span class="line">        scene.addMnemonic(mc3);</span><br><span class="line"></span><br><span class="line">        primaryStage.setScene(scene);</span><br><span class="line">        primaryStage.setTitle(<span class="string">&quot;javafx&quot;</span>);</span><br><span class="line">        primaryStage.setWidth(<span class="number">800</span>);</span><br><span class="line">        primaryStage.setHeight(<span class="number">500</span>);</span><br><span class="line">        primaryStage.show();</span><br><span class="line"></span><br><span class="line">    &#125;</span><br><span class="line">&#125;</span><br></pre></td></tr></table></figure>


        </div>

        
            <div class="post-copyright-info">
                <div class="article-copyright-info-container">
    <ul>
        <li>本文标题：JavaFX学习之按钮点击事件与快捷键绑定</li>
        <li>本文作者：Da</li>
        <li>创建时间：2021-05-22 11:53:29</li>
        <li>
            本文链接：https://da9527.gitee.io/2021/05/22/JavaFX学习之按钮点击事件与快捷键绑定/
        </li>
        <li>
            版权声明：本博客所有文章除特别声明外，均采用 <a class="license" target="_blank" rel="noopener" href="https://creativecommons.org/licenses/by-nc-sa/4.0/deed.zh">BY-NC-SA</a> 许可协议。转载请注明出处！
        </li>
    </ul>
</div>

            </div>
        

        
            <div class="article-nav">
                
                    <div class="article-prev">
                        <a class="prev"
                           rel="prev"
                           href="/2021/05/22/JavaFX%E5%AD%A6%E4%B9%A0%E4%B9%8B%E6%96%87%E6%9C%AC%E6%A1%86%E5%AF%86%E7%A0%81%E6%A1%86%E5%92%8CLabel%E6%A0%87%E7%AD%BE/"
                        >
                            <span class="left arrow-icon flex-center">
                              <i class="fas fa-chevron-left"></i>
                            </span>
                            <span class="title flex-center">
                                <span class="post-nav-title-item">JavaFX学习之文本框密码框和Label标签</span>
                                <span class="post-nav-item">上一篇</span>
                            </span>
                        </a>
                    </div>
                
                
                    <div class="article-next">
                        <a class="next"
                           rel="next"
                           href="/2021/05/22/JavaFX%E5%AD%A6%E4%B9%A0%E4%B9%8B%E6%8C%89%E9%92%AE%E6%A0%B7%E5%BC%8F%E8%AE%BE%E7%BD%AE/"
                        >
                            <span class="title flex-center">
                                <span class="post-nav-title-item">JavaFX学习之按钮样式设置</span>
                                <span class="post-nav-item">下一篇</span>
                            </span>
                            <span class="right arrow-icon flex-center">
                              <i class="fas fa-chevron-right"></i>
                            </span>
                        </a>
                    </div>
                
            </div>
        

        
    </div>
</div>


                
            </div>

        </div>

        <div class="page-main-content-bottom">
            <footer class="footer">
    <div class="info-container">
        <div class="copyright-info info-item">
            &copy;
            
              <span>2020</span>&nbsp;-&nbsp;
            
            2021&nbsp;<i class="fas fa-heart icon-animate"></i>&nbsp;<a href="/">Da</a>
        </div>
        
            <script async data-pjax src="//busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script>
            <div class="website-count info-item">
                
                    <span id="busuanzi_container_site_uv">
                        访问人数&nbsp;<span id="busuanzi_value_site_uv"></span>&ensp;
                    </span>
                
                
                    <span id="busuanzi_container_site_pv">
                        总访问量&nbsp;<span id="busuanzi_value_site_pv"></span>
                    </span>
                
            </div>
        
        <div class="theme-info info-item">
            由 <a target="_blank" href="https://hexo.io">Hexo</a> 驱动&nbsp;|&nbsp;主题&nbsp;<a class="theme-version" target="_blank" href="https://github.com/XPoet/hexo-theme-keep">Keep v3.4.2</a>
        </div>
        
    </div>
</footer>

        </div>
    </div>

    
        <div class="post-tools">
            <div class="post-tools-container">
    <ul class="tools-list">
        <!-- TOC aside toggle -->
        
            <li class="tools-item page-aside-toggle">
                <i class="fas fa-outdent"></i>
            </li>
        

        <!-- go comment -->
        
    </ul>
</div>

        </div>
    

    <div class="right-bottom-side-tools">
        <div class="side-tools-container">
    <ul class="side-tools-list">
        <li class="tools-item tool-font-adjust-plus flex-center">
            <i class="fas fa-search-plus"></i>
        </li>

        <li class="tools-item tool-font-adjust-minus flex-center">
            <i class="fas fa-search-minus"></i>
        </li>

        <li class="tools-item tool-expand-width flex-center">
            <i class="fas fa-arrows-alt-h"></i>
        </li>

        <li class="tools-item tool-dark-light-toggle flex-center">
            <i class="fas fa-moon"></i>
        </li>

        <!-- rss -->
        

        
            <li class="tools-item tool-scroll-to-top flex-center">
                <i class="fas fa-arrow-up"></i>
            </li>
        

        <li class="tools-item tool-scroll-to-bottom flex-center">
            <i class="fas fa-arrow-down"></i>
        </li>
    </ul>

    <ul class="exposed-tools-list">
        <li class="tools-item tool-toggle-show flex-center">
            <i class="fas fa-cog fa-spin"></i>
        </li>
        
    </ul>
</div>

    </div>

    
        <aside class="page-aside">
            <div class="post-toc-wrap">
    <div class="post-toc">
        <ol class="nav"><li class="nav-item nav-level-1"><a class="nav-link" href="#JavaFX%E7%9A%84%E7%AC%AC%E4%B8%83%E6%AC%A1%E6%8E%A5%E8%A7%A6"><span class="nav-text">JavaFX的第七次接触</span></a></li></ol>
    </div>
</div>
        </aside>
    

    <div class="image-viewer-container">
    <img src="">
</div>


    
        <div class="search-pop-overlay">
    <div class="popup search-popup">
        <div class="search-header">
          <span class="search-input-field-pre">
            <i class="fas fa-keyboard"></i>
          </span>
            <div class="search-input-container">
                <input autocomplete="off"
                       autocorrect="off"
                       autocapitalize="off"
                       placeholder="搜索..."
                       spellcheck="false"
                       type="search"
                       class="search-input"
                >
            </div>
            <span class="popup-btn-close">
                <i class="fas fa-times"></i>
            </span>
        </div>
        <div id="search-result">
            <div id="no-result">
                <i class="fas fa-spinner fa-pulse fa-5x fa-fw"></i>
            </div>
        </div>
    </div>
</div>

    

</main>




<script src="/js/utils.js"></script>

<script src="/js/main.js"></script>

<script src="/js/header-shrink.js"></script>

<script src="/js/back2top.js"></script>

<script src="/js/dark-light-toggle.js"></script>



    
<script src="/js/local-search.js"></script>




    
<script src="/js/code-copy.js"></script>




    
<script src="/js/lazyload.js"></script>



<div class="post-scripts pjax">
    
        
<script src="/js/left-side-toggle.js"></script>

<script src="/js/libs/anime.min.js"></script>

<script src="/js/toc.js"></script>

    
</div>


    
<script src="/js/libs/pjax.min.js"></script>

<script>
    window.addEventListener('DOMContentLoaded', () => {
        const pjax = new Pjax({
            selectors: [
                'head title',
                '.page-container',
                '.pjax'
            ],
            history: true,
            debug: false,
            cacheBust: false,
            timeout: 0,
            analytics: false,
            currentUrlFullReload: false,
            scrollRestoration: false,
            // scrollTo: true,
        });

        document.addEventListener('pjax:send', () => {
            KEEP.utils.pjaxProgressBarStart();
        });

        document.addEventListener('pjax:complete', () => {
            KEEP.utils.pjaxProgressBarEnd();
            pjax.executeScripts(document.querySelectorAll('script[data-pjax], .pjax script'));
            KEEP.refresh();
        });
    });
</script>



<script src="/live2dw/lib/L2Dwidget.min.js?094cbace49a39548bed64abff5988b05"></script><script>L2Dwidget.init({"pluginRootPath":"live2dw/","pluginJsPath":"lib/","pluginModelPath":"assets/","tagMode":false,"debug":false,"model":{"jsonPath":"/live2dw/assets/shizuku.model.json"},"display":{"position":"left","width":120,"height":240},"mobile":{"show":false},"log":false});</script></body>
</html>
